<form id="<?php echo $uniqid;?>" method="post" style="padding: 8px;">
    <table border="0" width="100%" cellspacing="1" cellpadding="5" class="formtable">
        <tr bgcolor="#FFFFFF">
            <td class="tlabel" >名称：</td>
            <td colspan="3">{{name}}</td>
        </tr>
        <tr bgcolor="#FFFFFF">
            <td class="tlabel"  width="10%">注册证号/信用代码：</td>
            <td colspan="3">{{params.licence}}</td>
        </tr>
        <tr bgcolor="#FFFFFF">
            <td class="tlabel"  width="10%">营业执照图片：</td>
            <td colspan="3"><img :src="params.licence_img" style="height: 460px;"></td>
        </tr>
        <tr bgcolor="#FFFFFF">
            <td class="tlabel" >审核状态：</td>
            <td colspan="3">
                <label><input name="status" type="radio" class="textbox-prompt" v-model="params.audit_company" value="2">审核成功</label>
                <label><input name="status" type="radio" class="textbox-prompt" v-model="params.audit_company" value="3">审核失败</label>
                <input class="forminput inputstyle" style="width: 400px;"
                       v-if="params.audit_company==3" type="text" v-model="params.company_reason" placeholder="请填写审核失败原因..">
            </td>
        </tr>
    </table>
</form>
<script>
    var companyauditviewVm = new Vue({
        el: '#<?php echo $uniqid;?>',
        data: {
            params: JSON.parse('<?php echo addslashes(json_encode($dataset));?>'),
            name: JSON.parse('<?php echo addslashes(json_encode($company_name));?>'),
        },
        methods: {
            submit: function () {
                $.post('/admin/audit/companystatus', {id:companyauditviewVm.params.company_id, status: companyauditviewVm.params.audit_company, reason:companyauditviewVm.params.company_reason}, function (data) {
                    if (data.ret == 0) {
                        $.messager.show({
                            title: '提示',
                            msg: data.msg,
                            timeout: 3000,
                            showType: 'slide'
                        });
                        $('#<?php echo $uniqid;?>').form('clear');
                        $("#companyauditdlg").dialog('close');
                        $("#companyaudit").datagrid('reload');
                    } else {
                        $.messager.alert('提示', data.msg, 'warning');
                    }
                }, 'json');
            },
        }
    });
    $(function () {
        $('#companyauditsubmit').click(function (data) {
            companyauditviewVm.submit();
        });
    });
</script>
